package com.joysuch.wwyt.edu.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.joysuch.wwyt.edu.entity.EduCertificateNotify;
import org.springframework.validation.annotation.Validated;

import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;

/**
 * 证书提醒Service接口
 *
 * @author eric
 * @date 2021-04-16
 */
@Validated
public interface EduCertificateNotifyService extends IService<EduCertificateNotify> {

    /**
     * 新增提醒
     * @param notify
     */
    void saveEduCertificateNotify(@NotNull EduCertificateNotify notify);

    /**
     * 根据提醒名称查询
     *
     * @param id
     * @param tenantId
     * @param orgCode
     * @param name
     * @return
     */
    EduCertificateNotify getByName(Long id, @NotNull Long tenantId, @NotEmpty String orgCode, @NotEmpty String name);

    /**
     * 根据证书id查询设置的提醒
     * @param certId
     * @return
     */
    EduCertificateNotify findByCertId(Long certId);
}
